/** make a list of SNP */
var snpList = mapContext.get("list");
if(snpList ==null)
	{
	snpList = new Array();
	mapContext.put("list",snpList);
	}

/* found a SNP */
if(snp!=null)
	{
	snpList.push(snp);
	if(snpList.length>=10)
		{
		/** we tell the Cursor to stop scanning the berkeleyDB */
	 	mapContext.put("stop",true);
		}
	}
/* we reached the end of the berkeleyDB */
else
	{
	print("<!-- End of loop -->\n");
	for(var i=0;i< snpList.length;i++)
		{
		var snp = snpList[i];
		print("<SNP>\n");
		print("   <name>"+ snp.getAcn() +"</name>\n");
		print("</SNP>\n");
		}
	}
